package cn.logo.service.impl;

import java.util.List;
import java.util.Stack;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import cn.logo.dao.AddressDao;
import cn.logo.entities.Address;
import cn.logo.entities.Area;
import cn.logo.entities.City;
import cn.logo.entities.Province;
import cn.logo.service.AddressService;

/**
 * 
 * @author leimiaosen
 *
 */
@Service
public class AddressServiceImpl implements AddressService {

	@Autowired
	private AddressDao ad;
	private Stack<String> a;
	
	@Override
	public List<Address> getAddress(int id) {
		return ad.getAddressByUserId(id);
	}

	@Override
	public List<Province> getAllProvince() {
		return ad.getAllProvince();
	}

	@Override
	public List<City> getAllCitys(String pid) {
		return ad.getAllCitys(pid);
	}

	@Override
	public List<Area> getAllAreas(String cid) {
		return ad.getAllAreas(cid);
	}
	
}
